<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%
request.setCharacterEncoding("UTF-8");
String htmlData = request.getParameter("content1") != null ? request.getParameter("content1") : "";
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
<link rel="shortcut icon" href="image/favicons.ico" type="image/x-icon" />
<link rel="stylesheet" href="<%=basePath%>common/default/default.css" />
	<link rel="stylesheet" href="<%=basePath%>common/plugins/code/prettify.css" />
	<script charset="utf-8" src="<%=basePath%>common/lang/kindeditor.js"></script>
	<script charset="utf-8" src="<%=basePath%>common/lang/zh_CN.js"></script>
	<script charset="utf-8" src="<%=basePath%>common/plugins/code/prettify.js"></script>
        <!-- Main content -->
        <section class="content" id="refundcontent">
          <div class="row">
            <div class="col-md-12">
			
              <div class="box box-danger">
                <div class="box-header">
                  
                  <section class="content-header">
			<h1>
			<ol class="breadcrumb">
				 
				<li>修改首页图片</li>
			</ol>
          </h1>

		  
        </section>
                </div>
                <div class="box-body">
                  <!-- phone mask -->
                  <div class="form-group">
               
					<div class="bg-info" style="padding:10px;">		
						<p>
							<form name="example" method="post" action="updatein?type=2" accept-charset="UTF-8">
							<input type="hidden" name="id"  value="${picinfo.id }" />
							产品类型：<input  style="margin-right:80px;" type="text" name="cpname" value="${picinfo.cpname }" /> 
							<br><br/>
							产品路径：<input  style="margin-right:80px;" type="text" name="url" value="${picinfo.url }" /><br><br/> 
			<div class="box box-info" style="height:300px;width:500px;">
                
                <div class="box-body" style="height:auto;overflow: hidden;">
                  <!-- Color Picker -->
                  <div class="form-group">
                    			<img id="img" src="${picinfo.imgurl } " width="307px" height="178px"/>

                    <label style="position: absolute;top:10px;right:10px;" for="fileupload_input" class="btn btn-info">上传图片</label>
                    <input type="file" name="files" id="fileupload_input" multiple style="display: none"/>
                    <input type="hidden" name="imgurl" id="picurl" value="${picinfo.imgurl }" />
                                    
                  </div><!-- /.form group -->
                </div><!-- /.box-body -->
              </div><!-- /.box -->
              

							
							<br />
							<input type="submit" name="button" class="btn  btn-info btn-xs info" value="提交内容" /> 
							<a  href="img?type=2" class="btn  btn-info btn-xs info" style="width:100px;">返回</a>
							</form>
						</p>
					</div>	
					 <div class="form-group">
					
                  </div><!-- /.form group -->
					
                  </div><!-- /.form group -->
                 
                </div><!-- /.box-body -->
              </div><!-- /.box -->

            </div><!-- /.col (left) -->
          </div><!-- /.row -->
        </section><!-- /.content -->

     <script type="text/javascript">

		$("#activitys").addClass("active");
		$("#activitys").find("li:first").next().addClass("active");


		$("#datetimepicker").datetimepicker({
			language: 'zh-CN',	
			minView: '2',
    		format: 'yyyy-mm-dd'
		});
     		
     		  $("#tijiao").click(function(){
     		  		var content =document.getElementById('Content').value;
     		  		alert(content);
     		  });
     		  
					$("#fileupload_input").fileupload({
					    url:"<%=basePath%>admin/uploadImg",
					    done:function(e,result){
								
					          $("#img").attr("src",result.result.entity);
					          $("#picurl").val(result.result.entity);
					    }
					});
     </script>
